home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sources.misc
- From: Dan Kegel <dank@blacks.jpl.nasa.gov>
- Subject: v20i007: log_archie - Script for easy access to Archie, Patch01
- Message-ID: <1991May22.040301.16686@sparky.IMD.Sterling.COM>
- X-Md4-Signature: 26029786cec321c65a36c648bfc53419
- Date: Wed, 22 May 1991 04:03:01 GMT
- Approved: kent@sparky.imd.sterling.com
-
- Submitted-by: Dan Kegel <dank@blacks.jpl.nasa.gov>
- Posting-number: Volume 20, Issue 7
- Archive-name: log_archie/patch01
- Patch-To: log_archie: Volume 19, Issue 63
-
- The awk script supplied in log_archie neglects to print the year
- part of each file's timestamp. A patch to postarchie.awk follows.
-
- Dan
- -----
- *** old.postarchie Tue May 21 22:48:28 1991
- --- postarchie.awk Tue May 21 22:51:27 1991
- ***************
- *** 3,10 ****
- # Output format is
- # hostname directory filename size date
- # padded with many tabs.
- ! # You WILL run into a bug in SunOS<=4.1.1b's sort utility if you run this stuff
- ! # through 'sort +2'; sort fails to ignore whitespace properly.
- /^Host / {host=$2 substr("\t\t\t\t\t\t", 1, (47-length($2))/8); next}
- /^ *Location:/ {dir=$2 substr("\t\t\t\t\t\t\t\t", 1, (63-length($2))/8); next}
- ! /^ *FILE/ { print host dir $7 substr("\t\t\t\t", 1, (31-length($7))/8) $3 " " $4 " " $5; next}
- --- 3,9 ----
- # Output format is
- # hostname directory filename size date
- # padded with many tabs.
- ! # Note: On SunOS, sort +2 fails on this scripts' output; use sort -b +2 instead.
- /^Host / {host=$2 substr("\t\t\t\t\t\t", 1, (47-length($2))/8); next}
- /^ *Location:/ {dir=$2 substr("\t\t\t\t\t\t\t\t", 1, (63-length($2))/8); next}
- ! /^ *FILE/ { print host dir $7 substr("\t\t\t\t", 1, (31-length($7))/8) $3 " " $4 " " $5 " " $6; next}
- exit 0 # Just in case...
- --
- Kent Landfield INTERNET: kent@sparky.IMD.Sterling.COM
- Sterling Software, IMD UUCP: uunet!sparky!kent
- Phone: (402) 291-8300 FAX: (402) 291-4362
- Please send comp.sources.misc-related mail to kent@uunet.uu.net.
-